using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using Adge.Models;
using NHibernate.Expression;
using Adge.Common;

namespace Adge.Web.UI.DesktopModules.Html
{
    public partial class friendLinks : System.Web.UI.UserControl
    {
        protected void Page_Load(object sender, EventArgs e)
        {            
            InitLinks();            
        }

        private void InitLinks()
        {
            Adge.BLL.AdgeArBase<LinksInfo> bll = new Adge.BLL.AdgeArBase<LinksInfo>();
            ICriterion[] criterias = new ICriterion[] { };
            LinksInfo[] lnks = bll.SlicedFindAll(0, AdgeConfig.LinkTitleNumber, new Order[] { Order.Desc("CreatedDate") }, criterias);
            dlLnks.DataSource = lnks;
            dlLnks.DataBind();
        }
    }
}